package com.ruoyi.web.controller.tool;

import com.ruoyi.common.utils.StringUtils;
import com.ruoyi.common.utils.http.HttpUtils;

public class ExpressUtil {

    private static String key = "99836eda42d92fc2f99262101b874ad9";

    public static String getExpressInfo(String com, String kddh, String sort) {
        if (StringUtils.isBlank(sort)) {
            sort = "desc";
        }
        String url = "http://api.kuaidi.com/openapi.html?id=" + key + "&com=" + com + "&nu=" + kddh + "&show=0&muti=0&order=" + sort;
        String result = HttpUtils.doGet(url);
        return result;
    }


}
